<template>
  <view class="login-container">
    <!-- 标题 -->
    <view class="login-title">登录</view>
    <!-- 头像区域 -->
    <view class="avatar-section">
      <view class="avatar"></view>
      <text class="nickname">植物魁首</text>
    </view>
    <!-- 登录按钮 -->
    <button class="login-button">手机号一键登录</button>
    <!-- 协议勾选 -->
    <view class="agreement mt-30">
      <checkbox
        :checked="true"
        class="agree-checkbox"
        @change="onAgreeChange"
      />
      <text class="agreement-text ">阅读并同意《用户协议》</text>
    </view>
    <!-- 底部切换登录方式 -->
    <view class="switch-login">账号密码登录</view>
  </view>
</template>
<script>
export default {
  data() {
    return {
      isAgreed: true,
    };
  },
  methods: {
    onAgreeChange(e) {
      this.isAgreed = e.detail.value;
    },
  },
};
</script>
<style lang="scss">
.login-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background-color: #ffffff;
  padding: 0 30rpx;
  .login-title {
    font-size: 32rpx;
    font-weight: bold;
    margin-bottom: 120rpx;
  }
  .avatar-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 80rpx;
    .avatar {
      width: 160rpx;
      height: 160rpx;
      border-radius: 50%;
      background-color: #e0e0e0;
      margin-bottom: 20rpx;
    }
    .nickname {
      font-size: 28rpx;
      color: #333333;
    }
  }
  .login-button {
    color: black;
    margin-top: 40rpx;
    width: 677rpx;
    height: 99rpx;
	background: linear-gradient( 90deg, #6BFFCB 0%, #45FF44 100%);
	border-radius: 1908px 1908px 1908px 1908px;

  }
  .agreement {
    display: flex;
    align-items: center;
    margin-bottom: 60rpx;
    .agree-checkbox {
      transform: scale(1.2);
      margin-right: 12rpx;
    }
    .agreement-text {
      font-size: 26rpx;
      color: #666666;
    }
  }
  .switch-login {
    font-size: 26rpx;
    color: #999999;
  }
}
</style>
